﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="VoteManage.aspx.cs" Inherits="Business_Cisoft3G_InboxManage_VoteManage" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>投票调查</title>
    <link href="../../../css/style.css" rel="stylesheet" type="text/css" />
    <link href="../../../css/font.css" rel="stylesheet" type="text/css" />
    <link href="../../../css/style_ts.css" rel="stylesheet" type="text/css" />
    
    <asp:Literal ID="ltScript" runat="server"></asp:Literal>
    
    <script type="text/javascript" src="../../../js/jquery-1.4.2.min.js"></script>

    <script type="text/javascript" src="../../../js/jquery.blockUI.js"></script>

    <script type="text/javascript" src="../../../js/CheckForm.js"></script>
    <style type="text/css">
        .modalBackground
        {
            background-color: Gray;
            filter: alpha(opacity=70);
            opacity: 0.7;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server" onsubmit=" return CheckForm()">
    <div class="position_list">
	    <div class="position_left_list"></div>
	    <div class="position_con_list">
	      <table border="0" cellpadding="0" cellspacing="0">
            <tr>
              <td width="30"><img src="../../../Images/3G/icon21.gif" width="14" height="14" alt="" /></td>
              <td class="cyan12">投票调查</td>
            </tr>
          </table>
	    </div>
	    <div class="position_right_list"></div>
	  </div>
	  <!--[if !IE]>搜素区域开始<![endif]-->
	  <div class="search_list">
	    <div class="search_top_list">
	      <div class="search_topleft_list"></div>
	      <!--  查询     -->
		  <div class="search_topbg_list">
		       <table border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td width="30" align="left" valign="middle" style="padding-top:4px;"><img src="../../../Images/3G/icon_logo.gif" width="22" height="22" /></td>
                <td width="100" class="cyan13_bold" style="padding-top:5px;">系统温馨提示栏</td>
                <td style="padding-top:5px;">
                    <%--<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ErrorMessage="开始日期格式错误!正确的日期格式为 YYYY-MM-DD"
                            Display="Dynamic" ControlToValidate="txtStartTime" ValidationExpression="^((\d{2}(([02468][048])|([13579][26]))[\-\/\s]?((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9])))))|(\d{2}(([02468][1235679])|([13579][01345789]))[\-\/\s]?((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$">
                        </asp:RegularExpressionValidator>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ErrorMessage="结束日期格式错误!正确的日期格式为 YYYY-MM-DD"
                            Display="Dynamic" ControlToValidate="txtEndTime" ValidationExpression="^((\d{2}(([02468][048])|([13579][26]))[\-\/\s]?((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|([1-2][0-9])))))|(\d{2}(([02468][1235679])|([13579][01345789]))[\-\/\s]?((((0?[13578])|(1[02]))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\-\/\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\-\/\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))))(\s(((0?[1-9])|(1[0-2]))\:([0-5][0-9])((\s)|(\:([0-5][0-9])\s))([AM|PM|am|pm]{2,2})))?$">
                        </asp:RegularExpressionValidator>--%>
                </td>
              </tr>
            </table>
		  </div>
		  <div class="search_topright_list"></div>
	    </div>
	    <!--   列表     -->
		<div class="index_search_con_list">
		    <table border="0" cellpadding="0" cellspacing="0" style="padding-left:10px">
                <tr>
                    <td>
                        <span style="color: #ffffff; font-weight: bold"><%--投票调查人：--%></span><input type="text" runat="server"
                            id="txtSent" style="height: 14px; width: 100px; border: 1px solid #ffffff; display:none"/>
                        <span style="color: #ffffff; font-weight: bold">投票主题内容：</span><input type="text" runat="server"
                            id="txtContent" style="height: 14px; width: 100px; border: 1px solid #ffffff;" />
                        <span style="color: #ffffff; font-weight: bold">开始时间：</span>
                        <%--<input type="text" runat="server" id="txtStartTime" style="height:14px; width:70px; border:1px solid #ffffff;" />--%>
                        <asp:TextBox ID="txtStartTime" runat="server" Style="height: 14px; width: 70px; border: 1px solid #ffffff;"></asp:TextBox> 
                        <img src="../../../Images/Calendar_scheduleHS.png" alt="点击选择开始日期" id="imgStartDate"
                            runat="server" />
                        <span style="color: #ffffff; font-weight: bold">结束时间：</span>
                        <%--<input type="text" runat="server" id="txtEndTime" style="height:14px; width:70px; border:1px solid #ffffff;" />--%>
                        <asp:TextBox ID="txtEndTime" runat="server" Style="height: 14px; width: 70px; border: 1px solid #ffffff;"></asp:TextBox>
                        <img src="../../../Images/Calendar_scheduleHS.png" alt="点击选择结束日期" id="imgEndDate"
                            runat="server" />&nbsp;&nbsp;<asp:Button ID="btnSearch" runat="server" Text="" OnClick="btnSearch_Click" />
                            <br />
                        
                        <asp:Button ID="btnAdd" runat="server" Text="" Onclick="btnAdd_Click"  />
                        <%--<asp:Button ID="btnDelete" runat="server" Text="" OnClick="Button1_Click" 
                            OnClientClick="if(CheckCheckBoxIsChecked(this)) {return confirm('您确认删除吗？');}else{alert('请选择要删除的记录！ '); return false;}" Visible="true"/>--%>
                        <asp:Button ID="btnDelete" runat="server" Text="" OnClick="LinkButton2_Click" OnClientClick="if(CheckCheckBoxIsChecked(this)){document.getElementById('hihDelete').value = 'true';}else{document.getElementById('hihDelete').value = 'false';}" />  
                        <asp:Button ID="btnExportThisPage" runat="server" ToolTip="导出本页记录"  
                            Text="" onclick="btnExportThisPage_Click" Visible="false"/>
                        <asp:Button ID="btnExportFilter" runat="server" Text="" ToolTip="导出筛选记录" 
                            onclick="btnExportFilter_Click" Visible="false"/>
                        <br />
                        
                        <br />
                    </td>
                </tr>
            </table>
            <asp:GridView ID="gvData" runat="server" AutoGenerateColumns="true">
            </asp:GridView>
		     <%--<ajax:AjaxPanel ID="AjaxPanel1" runat="server">--%>
            <table width="100%"  border="0" cellspacing="1" cellpadding="0" bgcolor="73798f" id="tableList">
                <tr class="cyan12" bgcolor="#1E3541">
                    <td width="25" height="20" valign="middle" style="text-align: center">
                        <asp:CheckBox ID="chcAll" runat="server" />
                    </td>
                    <td style="display: none;">
                    </td>
                    <td style="display: none;">
                    </td>
                    <td width="150" align="center" valign="middle" style="display: none;">
                        投票主题
                    </td>
                    <td align="center" valign="middle" style="min-width: 300px;">
                        投票主题内容
                    </td>
                    <td width="130" align="center" valign="middle">
                        投票开始时间
                    </td>
                    <td width="130" align="center" valign="middle">
                        统计从
                    </td>
                    <td width="130" align="center" valign="middle">
                        截止至
                    </td>
                    <td align="center" valign="middle">
                        操作
                    </td>
                </tr>
                <asp:Repeater ID="Repeater1" runat="server" OnItemCommand="Repeater1_ItemCommand">
                    <ItemTemplate>
                        <tr bgcolor="#1E3541" onmousemove="this.className='li_td_mouseover'" onmouseout="this.className='li_td_mouseout'">
                            <td height="20" align="center" valign="middle">
                                <asp:CheckBox ID="cbk_single" runat="server" name="cb1" />
                            </td>
                            <td style="display: none;">
                                <asp:Label ID="lblInboxID" runat="server" Text='<%#DataBinder.Eval(Container.DataItem, "VoteID")%>'></asp:Label>
                            </td>
                            <td style="display: none;">
                                <%--<asp:Label ID="lblSmsID" runat="server" Text='<%#DataBinder.Eval(Container.DataItem, "IB_SmsID")%>'></asp:Label>--%>
                            </td>
                            <td align="center" valign="middle" style="display: none;">
                               <%-- <%#DataBinder.Eval(Container.DataItem, "IB_Send")%>--%>
                            </td>
                           
                            <td align="left" valign="middle" class="td_li">
                                <%--<asp:Label ID="lblSmsContent" runat="server" Text='<%#DataBinder.Eval(Container.DataItem, "IB_SMContent").ToString().Length < 40 ?  DataBinder.Eval(Container.DataItem, "IB_SMContent").ToString().Substring(0, 38) + "...": DataBinder.Eval(Container.DataItem, "IB_SMContent").ToString()%>' 
                                ToolTip='<%#DataBinder.Eval(Container.DataItem, "IB_SMContent")%>'/>--%>
                                <asp:Label ID="lblSmsContent" runat="server" Text='<%#DataBinder.Eval(Container.DataItem, "VoteContent").ToString().Trim().Length > 32 ?  DataBinder.Eval(Container.DataItem, "VoteContent").ToString().Trim().Substring(0, 30) + "...": DataBinder.Eval(Container.DataItem, "VoteContent").ToString().Trim()%>'
                                    ToolTip='<%#DataBinder.Eval(Container.DataItem, "VoteContent").ToString().Trim()%>' />
                            </td>
                            <td align="center" valign="middle">
                                <%#DataBinder.Eval(Container.DataItem, "VoteSendTime")%>
                            </td>
                            <td align="center" valign="middle">
                                <%#DataBinder.Eval(Container.DataItem, "VoteStartTime")%>
                            </td>
                            <td align="center" valign="middle">
                                <%#DataBinder.Eval(Container.DataItem, "VoteEndTime")%>
                            </td>
                            <td width="90" align="center" valign="middle">
                                <asp:LinkButton ID="lbtnEditReSend" class="yellow12_link" runat="server" CommandName="EditReSend"
                                    CommandArgument='<%# Eval("VoteID")%>' Text='编辑重发' CausesValidation="false"></asp:LinkButton>
                                <asp:LinkButton ID="lblDetails" class="yellow12_link" runat="server" CommandName="Details"
                                    CommandArgument='<%# Eval("VoteID")%>' Text='查看' CausesValidation="false"></asp:LinkButton>
                                <%--<a href="#" target="_self" class="yellow12_link" title="查看">查看</a><a href="#" target="_self"
                                    class="yellow12_link"></a>--%>
                            </td>
                            <%--<td width="50" align="center" valign="middle"><a href="#" target="_self" class="green12_link" title="转发">转发</a><a href="#" target="_self" class="green12_link"></a></td>
                            <td width="50" align="center" valign="middle"><a href="#" target="_self" class="orange12_link" title="重发">重发</a><a href="#" target="_self" class="orange12_link"></a></td>--%>
                        </tr>
                    </ItemTemplate>
                    <FooterTemplate>
                        <tr>
                            <td colspan="7">
                                <asp:Label ID="lblEmpty" Text="对不起，未查询到记录。" ForeColor="Red" runat="server" Visible='<%#Repeater1.Items.Count <= 0%>'></asp:Label>
                            </td>
                        </tr>
                    </FooterTemplate>
                </asp:Repeater>
            </table>
            <%--</ajax:AjaxPanel>--%>
            <%--<div class="search_li">--%>
            <table width="100%" border="0" cellpadding="0" cellspacing="0">
                <tr>
                    <td>
                        <webdiyer:AspNetPager ID="AspNetPager1" runat="server" Width="100%" UrlPaging="false"
                            AlwaysShow="true" CustomInfoHTML="<span style:'height:18px;'></span><br/>共%PageCount%页 %RecordCount%条记录"
                            ShowCustomInfoSection="Left" FirstPageText="首页" PrevPageText="前一页" NextPageText="下一页"
                            LastPageText="末页" PageIndexBoxType="TextBox" ShowPageIndexBox="Always" TextBeforePageIndexBox="跳转到: "
                            SubmitButtonText="" SubmitButtonStyle="width:30px;height:21px;vertical-align:bottom;border:0px;background:url(../../../Images/3G/GO.gif) no-repeat;"
                            HorizontalAlign="right" PageSize="12" OnPageChanged="AspNetPager1_PageChanged"
                            EnableTheming="true">
                        </webdiyer:AspNetPager>
                    </td>
                </tr>
            </table>
            <%--</div>--%>
		</div>
		
	  </div>
	  
	  <div class="search_bottom_list">
		  <div class="search_bottomleft_list"></div>
		  <div class="search_bottombg_list"></div>
		  <div class="search_bottomright_list"></div>
		</div>
	  <!--[if !IE]>搜素区域结束<![endif]-->
    <asp:ScriptManager ID="Scriptmanager1" runat="server" EnableScriptGlobalization="true"
        EnableScriptLocalization="true">
    </asp:ScriptManager>
    <ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender3" runat="server" TargetControlID="LinkButton1"
        PopupControlID="appease_Panel1" BackgroundCssClass="modalBackground" OnOkScript="onOk()"
        DropShadow="true" PopupDragHandleControlID="appease_Panel2" CancelControlID="Close">
    </ajaxToolkit:ModalPopupExtender>
    <asp:Panel ID="appease_Panel1" runat="server" Style="display: none; background-color: #ffffdd;
        border-width: 3px; border-style: solid; border-color: Gray; padding: 3px; width: 500px;">
        <asp:Panel ID="appease_Panel2" runat="server" Style="cursor: move; background-color: #edc789;
            border: solid 1px Gray; color: Black; height: 20px; vertical-align: middle;">
            <div>
                <h3 style="text-align: center; height: 20px; vertical-align: middle;">
                    详细信息</h3>
            </div>
        </asp:Panel>
        <div>
            <asp:Panel ID="appease_Panel3" runat="server" Height="170px">
                
                <table border="2" cellpadding="5" cellspacing="1" bordercolor="#edc789" style="width: 500px;
                    text-align: center; background-color: #ffffff; border-collapse: collapse;">
                    <tr>
                        <td align="right">
                            短信类型：
                        </td>
                        <td style="width: 380px; text-align: left">
                            <asp:Label ID="lblType" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            投票调查人：
                        </td>
                        <td style="width: 380px; text-align: left">
                            <asp:Label ID="lblSend" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            接收人：
                        </td>
                        <td style="width: 380px; text-align: left">
                            <asp:Label ID="lblRecive" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            投票调查内容：
                        </td>
                        <td style="width: 380px; text-align: left">
                            <asp:Label ID="lblContent" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            投票调查时间：
                        </td>
                        <td style="width: 380px; text-align: left">
                            <asp:Label ID="lblSendTime" runat="server" Text=""></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td align="center" class="navi_link" colspan="2">
                            <asp:Button ID="Close" runat="server" Text="" />
                            <asp:Button ID="CancleButton" runat="server" Text="Cancle" Visible="false" />
                        </td>
                    </tr>
                </table>
            </asp:Panel>
        </div>
    </asp:Panel>
    <%--<asp:LinkButton ID="LinkButton1" runat="server" Visible="true" OnClick="LinkButton1_Click"></asp:LinkButton>--%>
     <ajaxToolkit:ModalPopupExtender ID="ModalPopupExtender1" runat="server" TargetControlID="LinkButton2"
        PopupControlID="Panel1" BackgroundCssClass="modalBackground" OnOkScript="onOk()"
        DropShadow="false" PopupDragHandleControlID="Panel2" CancelControlID="btnCloseAll2">
    </ajaxToolkit:ModalPopupExtender>
    <asp:Panel ID="Panel1" runat="server" Style="display: none; width: 26%;
        vertical-align: middle;">
        <div class="attention_delete">
            <asp:Panel ID="Panel2" runat="server" Style="vertical-align: middle;">
                <div class="attention_top">
                    <div class="attention_topleft">
                    </div>
                    <div class="attention_topmid_delete">
                        <table width="98%" border="0" cellpadding="0" cellspacing="0">
                            <tr>
                                <td align="left" valign="middle" class="title">
                                    提示信息
                                </td>
                                <td align="right" valign="middle" width="30">
                                    <asp:Button ID="btnCloseAll2" runat="server" Text="" />
                                </td>
                            </tr>
                        </table>
                    </div>
                    <div class="attention_topright">
                    </div>
                </div>
            </asp:Panel>
            <div class="attention_con">
                <asp:Panel ID="Panel3" runat="server">
                    <table border="1" runat="server" id="table2" cellpadding="5" cellspacing="0" bordercolor="#0e62a7"
                        style="width: 100%; text-align: center; border-collapse: collapse;">
                        <tr>
                            <td style="text-align: Center">
                                <asp:Label ID="lblTS" runat="server" Text=""></asp:Label>
                            </td>
                        </tr>
                        <tr>
                            <td align="center" class="navi_link">
                                <asp:Button ID="btnConfirm2" runat="server" ToolTip="确定" OnClick="btnConfirm2_Click"/>
                                <asp:Button ID="btnConfirm3" runat="server" ToolTip="确定" Style="display: none;" />
                                <asp:Button ID="btnCancel" runat="server" Visible="false" />
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
            </div>
        </div>
    </asp:Panel>
    <input type="hidden" value="" runat="server" id="hihDelete"/>
    <asp:LinkButton ID="LinkButton1" runat="server" Visible="true" OnClick="LinkButton1_Click"></asp:LinkButton>
    <asp:LinkButton ID="LinkButton2" runat="server" Visible="true" OnClick="LinkButton2_Click"></asp:LinkButton>
    </form>
</body>
</html>
